﻿<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />



<link type="text/css" href="../css/smoothness/jquery-ui-1.7.1.custom.css" rel="stylesheet" />
<link href="../css/default.css" rel="stylesheet" type="text/css"/>	
<link href="saler.css" rel="stylesheet" type="text/css"/>	
<script type="text/javascript" src="../js/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="../js/jquery-ui-1.7.1.custom.min.js"></script>

	<script type="text/javascript" src='../js/plugin/jquery.clockpick.1.2.5.js'></script>    
	<link type="text/css" href='../js/plugin/clockpick.1.2.5.css' rel="stylesheet" />

<link href="facebox/facebox.css" media="screen" rel="stylesheet" type="text/css"/>
<script src="facebox/facebox.js" type="text/javascript"></script>


	<script type="text/javascript">
	$(function() {	
		$(".todotime").clockpick();	
		$('a[rel*=facebox]').facebox();	
		$('#tabs').tabs();	
	});
	</script>
    

<title>Untitled Document</title>
</head>

<body>

<p>
  <?php 
//
include_once("..\\common.php");
$admin = false; 
CheckSalerLogon();
?>
  
  
<a href="index.php">回主页</a></p>
<p>&nbsp;</p>
<p>&nbsp; </p>
<div class = 'align-center' style="width:500" >
  <?php 

require_once("listclienttodo.php");

$salerid = $_SESSION["salerid"];
$DB = DBConnect();
$offsetday = 0;//$_GET["offsetday"];
$daycount = 3;//$_GET['daycout'];
	
?>
  
  <?php 
echo "<div id='tabs'>";

//
echo "<ul>";
for($day = $offsetday-$daycount;$day<=$offsetday+$daycount; $day++)
{
	$startdate = mktime(); //取得当前时间戳
	$lastdate = $day*3600*24 +$startdate; //算的60天后的时间戳
	$lastdate = date("Y-m-d",$lastdate); //得到60天后的日期时
	$tabname = sprintf("#tabs-%d",$day);
	if($day==0)$lastdate = "今日";
	
	echo "<li><a href='"; echo $tabname; echo "'>"; echo $lastdate; echo "</a></li>";	
}
echo "</ul>";

for($day = $offsetday-$daycount;$day<=$offsetday+$daycount; $day++)
{
	$tabname = sprintf("tabs-%d",$day);	
	
	echo "<div id='"; echo $tabname; echo "'>"; 
		ListTodoList($salerid,$DB,$day);
	echo "</div>";
}		
            
echo "</div>";

?>
  
</div>
</body>
</html>